package com.yunpeng.aidevice.common.vo;

import com.yunpeng.aidevice.common.vo.org.OrgPermissionVO;
import com.yunpeng.aidevice.common.vo.user.UserPermissionVO;

import java.io.Serializable;
import java.util.List;

/**
 * PermissionDetailVO 权限详情视图
 *
 * @author : Moore(hemw)
 * @date : 2020-04-15
 */
public class PermissionDetailVO implements Serializable {


    /**
     * 权限名称
     */
    private String name;

    /**
     * 权限代码
     */
    private String code;

    /**
     * 是否已禁用
     */
    private Boolean disabled;

    /**
     * 可操作此权限的角色
     */
    private List<RolePermissionVO> roles;

    /**
     * 拥有此权限的用户
     */
    private List<UserPermissionVO> users;

    /**
     * 可操作此权限的组织
     */
    private List<OrgPermissionVO> organizations;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public Boolean getDisabled() {
        return disabled;
    }

    public void setDisabled(Boolean disabled) {
        this.disabled = disabled;
    }

    public List<RolePermissionVO> getRoles() {
        return roles;
    }

    public void setRoles(List<RolePermissionVO> roles) {
        this.roles = roles;
    }

    public List<UserPermissionVO> getUsers() {
        return users;
    }

    public void setUsers(List<UserPermissionVO> users) {
        this.users = users;
    }

    public List<OrgPermissionVO> getOrganizations() {
        return organizations;
    }

    public void setOrganizations(List<OrgPermissionVO> organizations) {
        this.organizations = organizations;
    }

    @Override
    public String toString() {
        return "PermissionDetailVO{" +
                "name='" + name + '\'' +
                ", code='" + code + '\'' +
                ", disabled=" + disabled +
                ", roles=" + roles +
                ", users=" + users +
                ", organizations=" + organizations +
                '}';
    }
}
